import 'package:flutter/material.dart';
import 'package:text_style_demo/text_base.dart';
import 'package:text_style_demo/text_decoration.dart';
import 'package:text_style_demo/text_style.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'TextStyle Demo',
      home: MyHomePage(),
    );
  }
}

class MyHomePage extends StatefulWidget {
  @override
  _MyHomePageState createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        // Here we take the value from the MyHomePage object that was created by
        // the App.build method, and use it to set our appbar title.
        title: Text('TextStyleDemo'),
      ),
      body: ListView(children: [
        ListTile(
            title: Text('Text基础属性'),
            onTap: () {
              Navigator.of(context).push(
                  MaterialPageRoute(builder: (context) => TextBaseWidget()));
            }),
        ListTile(
            title: Text('TextStyle()'),
            onTap: () {
              Navigator.of(context).push(
                  MaterialPageRoute(builder: (context) => TextStyleWidget()));
            }),
        ListTile(
            title: Text('TextDecoration'),
            onTap: () {
              Navigator.of(context).push(MaterialPageRoute(
                  builder: (context) => TextDecorationWidget()));
            })
      ]),
    );
  }
}
